import 'package:honeypotflutter/net/public_http.dart';
import 'package:honeypotflutter/publicBussine/view/bussine_modal.dart';

class FreePayApi {
  /*
  * 切换数据
  * */
  static Future<bool> exchange(int type) async {
    try {
      Map param = {"userFirstChoicePayType": type};
      await MGHttp.post("api/services/app/UserSetting/SetUserPaySetting", params: param, progress: "数据切换中...");
      print("xxxxxxxxxxxxxxxxxxxxxxxxx");
      return true;
    } catch (error) {
      MGModal.totalError(error);
      return Future.error(error);
    }
  }
}
